package cn.ubeta.b2c.api;

import cn.ubeta.b2c.bean.FoundInfo;
import cn.ubeta.b2c.utils.NetworkCallback;
import cn.ubeta.b2c.utils.NetworkHelper;

import java.util.List;

/**
 * Created by denny on 16/9/5.
 */

public class ApiTopic {

    private static final String PATH = "/topic";

    public static void getTopicList(NetworkCallback<List<FoundInfo>> cb) {
        List<FoundInfo> test = FoundInfo.getTestData();
        if (test != null) {
            cb.onResponse(test);
        } else {
            NetworkHelper.call(PATH + "/list", cb);
        }
    }
}
